'''
Created on 2012-7-27
列表解析
@author: root
'''
list = [1,9,8,4]
#语法关键 sth (for) elem (in) list,加上筛选条件，甚至可以完全替换原来列表中到元素
list = [elem for elem in list if elem%2==0]
print(list) 